package AlexDB.MDB;

import java.util.HashMap;

public class DataBase {
    private static DataBase database = new DataBase();

    private DataBase(){
        
    }

    public static DataBase getDb(){
        return database;
    }
    
    public static HashMap<String,Object> dataMap = new HashMap<String,Object>();

    public static Object getDbMapObj(Class<?> classType){
        return dataMap.get(classType.getName());
    }
    
    
    public static Object putDbMapObj(Class<?> classType,Object obj){
        dataMap.put(classType.getName(), obj);
        return obj;
    }

    public static Object removeDbMapObj(Class<?> classType){
        return dataMap.remove(classType.getName());
    }

}

